package com.my.study.designPatterns.compoundPattern;

/**
 * 没有装饰者的鸭子工厂
 */
public class DuckFactory extends AbstractDuckFactory {

    @Override
    public Quackable redDuck() {
        return new RedHeadDuck();
    }

    @Override
    public Quackable yellowDuck() {
        return new YellowHeadDuck();
    }

    @Override
    public Quackable greenDuck() {
        return new GreenHeadDuck();
    }
}
